import tsb.trinhnx.main.BigNumber;

public class Euler016 {
	public static void main(String[] args) {
		// Calculate 2^1000 = 1024^100
		long start = System.currentTimeMillis();
		BigNumber result = BigNumber.ONE;
		for (int j = 0; j < 100; j++) {
			BigNumber temp = new BigNumber(1024);
			result = result.multipleBigNumber(temp);
		}
		final String out = result.toString();
		int sum = 0;
		for (int i = 0; i < out.length(); i++) {
			sum = sum + (out.charAt(i) - '0');
		}
		System.out.println("Sum: " + sum + "\n" + out);
		System.out.println("Time: " + (System.currentTimeMillis() - start));

	}
}